package com.liusand.activity.config;

import com.liusand.activity.interceptor.ActivityInterceptor;
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport;

/**
 * @author :liusha
 * packageName :com.liusand.activity.config
 * fileName :MvcConfig
 * creationTime :2022/12/22 16:19
 */
@SpringBootConfiguration
public class MvcSupport extends WebMvcConfigurationSupport {
    @Override
    protected void addInterceptors(InterceptorRegistry registry) {
        registry.addInterceptor(new ActivityInterceptor())
                .addPathPatterns("/**")
                .excludePathPatterns();
    }
}
